home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / bench / x.txt / 000212_fdc@columbia.edu_Thu Dec 6 15:08:30 EST 2001.msg < prev    next >
Text File  |  2020-01-01  |  2KB  |  50 lines

  1. Article: 13035 of comp.protocols.kermit.misc
  2. Path: newsmaster.cc.columbia.edu!news.columbia.edu!news-not-for-mail
  3. From: fdc@columbia.edu (Frank da Cruz)
  4. Newsgroups: comp.os.linux.misc,comp.protocols.kermit.misc
  5. Subject: Can't open("/dev/tty",O_RDWR) in RH7.1/ia64
  6. Date: 6 Dec 2001 14:09:55 -0500
  7. Organization: Columbia University
  8. Lines: 34
  9. Message-ID: <9uofq3$otq$1@watsol.cc.columbia.edu>
  10. NNTP-Posting-Host: watsol.cc.columbia.edu
  11. X-Trace: newsmaster.cc.columbia.edu 1007665796 10606 128.59.39.139 (6 Dec 2001 19:09:56 GMT)
  12. X-Complaints-To: postmaster@columbia.edu
  13. NNTP-Posting-Date: 6 Dec 2001 19:09:56 GMT
  14. Xref: newsmaster.cc.columbia.edu comp.os.linux.misc:529688 comp.protocols.kermit.misc:13035
  15.  
  16.  
  17. In the following program:
  18.  
  19.   extern int errno;
  20.   main() {
  21.       int fd;
  22.       errno = 0;
  23.       fd = open("/dev/tty",2);
  24.       printf("fd = %d\n",fd);
  25.       printf("errno = %d\n",errno);
  26.   }
  27.  
  28. open() returns -1 with errno = 6 ("No such device or address")
  29. on the following platform:
  30.  
  31. uname -a:
  32.   Linux spe190 2.4.9-12smp #1 SMP Tue Oct 30 17:55:42 EST 2001 ia64 unknown
  33.  
  34. /etc/issue:
  35.   Red Hat Linux release 7.1 (Seawolf)
  36.   Kernel 2.4.9-12smp on a 4-processor ia64
  37.  
  38. Of course there is such a device or address:
  39.  
  40. ls -l /dev/tty:
  41.   crw-rw-rw-    1 root     root       5,   0 Dec  5 12:28 /dev/tty
  42.  
  43. This prevents me from getting Kermit to work on this platform.  I tried
  44. simply substituing '0' as a file descriptor if open() fails, but then
  45. subsequent calls to tcsetattr(), etc, fail with "Bad file descriptor".
  46.  
  47. Does anybody know what's up?
  48.  
  49. - Frank
  50.